package cn.xuguowen.user.designPatten.strategy.hsp.tradition;

/**
 * ClassName: Duck
 * Package: cn.xuguowen.user.designPatten.strategy.hsp.tradition
 * Description:
 * 鸭子抽象类
 * @Author 徐国文
 * @Create 2023/4/28 12:10
 * @Version 1.0
 */
public abstract class Duck {

    public abstract void display();

    public void quack() {
        System.out.println("鸭子嘎嘎叫");
    }

    public void swim() {
        System.out.println("鸭子会游泳");
    }

    public void fly() {
        System.out.println("鸭子会飞行");
    }

}
